unit uFrmAbout;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, StdCtrls, ExtCtrls;

type
  TFrmAbout = class(TForm)
    Image1: TImage;
    Button1: TButton;
    lbl_Version: TLabel;
    procedure FormKeyPress(Sender: TObject; var Key: Char);
    procedure Button1Click(Sender: TObject);
    procedure FormShow(Sender: TObject);
    procedure FormClick(Sender: TObject);
    procedure FormCreate(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  FrmAbout: TFrmAbout;

implementation

uses uUtils, ufrmmain;
{$R *.dfm}

procedure TFrmAbout.Button1Click(Sender: TObject);
begin
  close();
end;

procedure TFrmAbout.FormClick(Sender: TObject);
begin
  close();
end;

procedure TFrmAbout.FormCreate(Sender: TObject);
begin
 Image1.Picture := FrmMain.img_Logo.Picture;
end;

procedure TFrmAbout.FormKeyPress(Sender: TObject; var Key: Char);
begin
  // The Escape key is #27.
  if Key = #27 then
    close;
end;

procedure TFrmAbout.FormShow(Sender: TObject);
begin
  lbl_Version.Caption := GetAppVersion(Application.ExeName);
end;

end.
